#ifndef SINGLETON_HPP
#define SINGLETON_HPP

#include <concepts>
#include <type_traits>

template<typename T>
struct PublicSingleton {
    static T& Instance() {
        static T inst{};
        return inst;
    }

protected:
    using Base = PublicSingleton<T>;
};

#define SINGLETON_TYPE() friend Base

#endif /* SINGLETON_HPP */
